<html xmlns:th="http://www.thymeleaf.org" xmlns:shiro="http://www.pollix.at/thymeleaf/shiro">
<head th:replace="common::header"></head>
<body>
<div class="layui-fluid">
	<div class="layui-row">
		<div class="layui-col-md12">
			<div class="layui-card">
				<div class="layui-card-header t-title layui-bg-cyan mlk-title">角色权限管理</div>
				<div class="layui-card-body">
					<table lay-filter="roleFilter" class="layui-table" id="roleFilter"></table>
				</div>
			</div>
		</div>
	</div>
</div>

</body>
<!--角色新增-->
<div id="add" class="mlk-hide">
	<div class="layui-fluid">
		<form class="layui-form layui-form-pane" lay-filter="addForm">
			<div class="layui-form-item">
				<label class="layui-form-label">角色名称</label>
				<div class="layui-input-block">
					<input type="text" name="name" required  lay-verify="required" placeholder="请输入角色名称" autocomplete="off" class="layui-input">
				</div>
			</div>
			<div class="layui-form-item">
				<label class="layui-form-label">角色标志符</label>
				<div class="layui-input-block">
					<input type="text" name="roleDesc" required  lay-verify="required" placeholder="请输入角色标志符" autocomplete="off" class="layui-input">
				</div>
			</div>
			<div class="layui-form-item">
				<label class="layui-form-label">角色权重</label>
				<div class="layui-input-block">
					<input type="text" name="seq" required  lay-verify="required|number" placeholder="请输入角色权重" autocomplete="off" class="layui-input">
				</div>
			</div>
			<div class="layui-form-item layui-form-text">
				<label class="layui-form-label">备注信息</label>
				<div class="layui-input-block">
					<textarea name="remark" placeholder="请输入备注信息" class="layui-textarea"></textarea>
				</div>
			</div>
			<div class="layui-form-item">
				<button class="layui-btn layui-btn-fluid" lay-submit lay-filter="add">立即提交</button>
			</div>
		</form>
	</div>
</div>
<!-- 角色编辑 -->
<div id="edit" class="mlk-hide">
	<div class="layui-fluid">
		<form class="layui-form layui-form-pane" lay-filter="editForm">
			<input name="id"  type="hidden">
			<div class="layui-form-item">
				<label class="layui-form-label">角色名称</label>
				<div class="layui-input-block">
					<input type="text" name="name" required  lay-verify="required" placeholder="请输入角色名称" autocomplete="off" class="layui-input">
				</div>
			</div>
			<div class="layui-form-item">
				<label class="layui-form-label">角色权重</label>
				<div class="layui-input-block">
					<input type="text" name="seq" required  lay-verify="required|number" placeholder="请输入角色权重" autocomplete="off" class="layui-input">
				</div>
			</div>
			<div class="layui-form-item layui-form-text">
				<label class="layui-form-label">备注信息</label>
				<div class="layui-input-block">
					<textarea name="remark" placeholder="请输入备注信息" class="layui-textarea"></textarea>
				</div>
			</div>
			<div class="layui-form-item">
				<button class="layui-btn layui-btn-fluid" lay-submit lay-filter="submit">立即提交</button>
			</div>
		</form>
	</div>
</div>

<!-- 权限弹出层 -->
<div class="layui-fluid mlk-hide" id="authTree">
	<div class="layui-row">
		<form class="layui-form">
			<div class="layui-form-item">
				<div class="layui-input-block">
					<div id="LAY-auth-tree-index"></div>
				</div>
			</div>
		</form>
	</div>
</div>
<script type="text/html" id="tool">
	<button class="layui-btn layui-btn-sm layui-btn-danger" lay-event="changeStatus">冻结或激活</button>
	<button class="layui-btn layui-btn-sm layui-btn-warm" lay-event="edit">编辑</button>
	<button class="layui-btn layui-btn-sm layui-btn-normal" lay-event="acledit">权限维护</button>
</script>
<script type="text/html" id="toolbar">
	<button class="layui-btn" lay-event="add">添加角色</button>
</script>
<div th:include="common::footer"></div>
<script type="text/javascript" th:src="@{/js/rbac/role.js}"></script>
</html>